home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Your Choice 3
/
Your Choice Software Collection 3.iso
/
os2
/
etelr21
/
getcrncy.vrm
< prev
next >
Wrap
Text File
|
1994-09-04
|
3KB
|
90 lines
/* Custom mainline for macro */
call RXFuncAdd "VRLoadFuncs", "VROBJ", "VRLoadFuncs"
call VRLoadFuncs
_VREVersion = SubWord( VRVersion( "VRObj" ), 1, 1 )
if( _VREVersion < 2.10 )then do
call VRMessage "", "This program requires VX-REXX version 2.1 to run.", "Error!"
return 32000
end
signal on SYNTAX name _VRESyntax
signal _VREMain
_VRESyntax:
parse source . . _VRESourceSpec
call VRMessage "", "Syntax error in" _VRESourceSpec "line" SIGL":" ErrorText(rc), "Error!"
exit 32000
_VREMain:
/*:VRX Main
*/
Main:
/*****************************************************/
/* Macro for fetching currency settings from os2.ini */
/* Please do not modify */
/*****************************************************/
iCurrency = VRGetIni( 'PM_National', 'iCurrency', 'User', 'NoClose' )
iDigits = VRGetIni( 'PM_National', 'iDigits', 'User', 'NoClose' )
iLzero = VRGetIni( 'PM_National', 'iLzero', 'User', 'NoClose' )
sThousand = VRGetIni( 'PM_National', 'sThousand', 'User', 'NoClose' )
sDecimal = VRGetIni( 'PM_National', 'sDecimal', 'User', 'NoClose' )
sCurrency = VRGetIni( 'PM_National', 'sCurrency', 'User' )
if iCurrency = '' then
iCurrency = '0'
if iDigits = '' | POS( '0', iDigits ) <> 0 then
iDigits = '2'
if( POS( '1', iDigits ) <> 0 )then
iDigits = '1'
if( POS( '2', iDigits ) <> 0 )then
iDigits = '2'
if( POS( '3', iDigits ) <> 0 )then
iDigits = '3'
if iLzero = '' then
iLzero = '0'
if sThousand = '' then
sThousand = ','
if sDecimal = '' then
sDecimal = '.'
if sCurrency = '' then
sCurrency = '$'
if POS( "$", sCurrency ) <> 0 then sCurrency = "$"
if POS( "Ö", sCurrency ) <> 0 then sCurrency = "Ö"
if POS( "Kr", sCurrency ) <> 0 then sCurrency = "Kr"
if POS( "\", sCurrency ) <> 0 then sCurrency = "\"
if POS( "NT$", sCurrency ) <> 0 then sCurrency = "NT$"
if POS( "ƒ", sCurrency ) <> 0 then sCurrency = "ƒ"
if POS( "x", sCurrency ) <> 0 then sCurrency = "x"
if POS( "F", sCurrency ) <> 0 then sCurrency = "F"
if POS( "mk", sCurrency ) <> 0 then sCurrency = "mk"
if POS( "Fr", sCurrency ) <> 0 then sCurrency = "Fr"
if POS( "SEK", sCurrency ) <> 0 then sCurrency = "SEK"
if POS( "Kƒs", sCurrency ) <> 0 then sCurrency = "Kƒs"
if POS( "FT", sCurrency ) <> 0 then sCurrency = "FT"
if POS( "╓kr", sCurrency ) <> 0 then sCurrency = "╓kr"
if POS( "Zê", sCurrency ) <> 0 then sCurrency = "Zê"
if POS( "Pts", sCurrency ) <> 0 then sCurrency = "Pts"
if POS( "TL", sCurrency ) <> 0 then sCurrency = "TL"
if POS( "Din", sCurrency ) <> 0 then sCurrency = "Din"
if POS( "Cr$", sCurrency ) <> 0 then sCurrency = "Cr$"
if POS( "£", sCurrency ) <> 0 then sCurrency = "£"
if POS( 'ñ', sCurrency ) <> 0 then sCurrency = 'ñ'
if POS( "DM", sCurrency ) <> 0 then sCurrency = "DM"
if POS( "kr", sCurrency ) <> 0 then sCurrency = "kr"
if POS( "BEF", sCurrency ) <> 0 then sCurrency = "BEF"
if POS( "L.", sCurrency ) <> 0 then sCurrency = "L."
if( POS( "2", iCurrency ) <> 0 )then sCurrency = sCurrency||" "
if( POS( "3", iCurrency ) <> 0 )then sCurrency = " "||sCurrency
currency.0 = 6
currency.1 = iCurrency
currency.2 = iDigits
currency.3 = iLzero
currency.4 = sThousand
currency.5 = sDecimal
currency.6 = sCurrency
call VRMethod 'Application', 'PutVar', 'currency.'
exit